<%@page import="com.wanmait.cookBook.vo.Admin"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
 
<!DOCTYPE html>
<html class="x-admin-sm">
    <head>
        <meta charset="UTF-8">
        <title>欢迎页面-X-admin2.2</title>
        <meta name="renderer" content="webkit">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
      
      <style>
          
          .ke{
              overflow:hidden;
	          position:relative;
	          display:table-cell;
	          text-align:center;
          	  vertical-align:middle;
          	  color:maroon;
          	  font-size:16px;
          }
          
          
        </style>
      
        <%  
			String path = request.getContextPath();  
			String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";  
		%> 
        
        <link rel="stylesheet" href="<%=path %>/back/css/font.css">
        <link rel="stylesheet" href="<%=path %>/back/css/xadmin.css">
        <script src="<%=path %>/back/lib/layui/layui.js" charset="utf-8"></script>
        <script type="text/javascript" src="<%=path %>/back/js/xadmin.js"></script>
        <script src="<%=path %>/back/js/jquery-3.5.1.min.js"></script>
        <style>
        	.nie{
        		padding-left:400px;
        	}
        	.yan{
        	margin-left:80px;
        		font-size:22px;
        		color:#FD2929;
        	}
        	
        </style>
        <script type="text/javascript">
           setInterval(s,1000);
           
           function s()
           {
                //获得当前的系统时间  并且显示到div中间
                //Date类
               var today = new Date();//创建Date的对象  调用Date的构造方法 该构造方法获得当前的系统时间

                var year = today.getFullYear();
               var month = today.getMonth()+1;
               var day = today.getDate();
               var hh = today.getHours();
               var min = today.getMinutes();
               var se = today.getSeconds();
               var time = year+"-"+month+"-"+day+"  "+hh+":"+min+":"+se;

               //设置到div  设置div的innerHTML   span  div   p a  td  ......
               var dx = $("#d");//获得div对象
               dx.html(time);//设置div的innerHTML的内容               
           }
           
           $(function(){
           	<%       		
   	   			Admin admin = (Admin)session.getAttribute("loginuser");
		
      			%>
              });
           
           
       </script>
        <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
        <!--[if lt IE 9]>
          <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
          <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
        <![endif]-->
        
    </head>
    <body>
        <div class="layui-fluid">
            <div class="layui-row layui-col-space15">
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-body ">
                            <blockquote class="layui-elem-quote">欢迎管理员：
                           
                                <span class="x-red"><%=admin.getAdminName() %></span>！&nbsp;&nbsp;&nbsp;&nbsp;<span id="d"></span>
                            </blockquote>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-header">数据统计</div>
                        <div class="layui-card-body ">
                            <ul class="layui-row layui-col-space10 layui-this x-admin-carousel x-admin-backlog">
                                <li class="layui-col-md2 layui-col-xs6">
                               <a class="x-admin-backlog-body">
                                        <h3>用户数</h3>
                                        <p>
                                         <%int sum2 = (int)session.getAttribute("sum2"); %>   
                                        	<cite><%=sum2 %></cite>
                                        </p>
                                    </a>
                                </li>
                                <li class="layui-col-md2 layui-col-xs6">
                                    <a class="x-admin-backlog-body">
                                        <h3>作品数</h3>
                                        <p>
                                        <%int sum1 = (int)session.getAttribute("sum1"); %>
                                            <cite><%=sum1 %></cite></p>
                                    </a>
                                </li>
                                <li class="layui-col-md2 layui-col-xs6">
                                    <a class="x-admin-backlog-body">
                                        <h3>食材类型数</h3>
                                        <p>
                                        <%int sum3 = (int)session.getAttribute("sum3"); %>
                                            <cite><%=sum3 %></cite></p>
                                    </a>
                                </li>
                                <li class="layui-col-md2 layui-col-xs6">
                                    <a class="x-admin-backlog-body">
                                        <h3>口味数</h3>
                                        <p>
                                        <%int sum4 = (int)session.getAttribute("sum4"); %>
                                            <cite><%=sum4 %></cite></p>
                                    </a>
                                </li>
                                <li class="layui-col-md2 layui-col-xs6">
                                    <a class="x-admin-backlog-body">
                                        <h3>日志数</h3>
                                        <p>
                                        <%int sum5 = (int)session.getAttribute("sum5"); %>
                                            <cite><%=sum5 %></cite></p>
                                    </a>
                                </li>
                                <li class="layui-col-md2 layui-col-xs6 ">
                                    <a class="x-admin-backlog-body">
                                        <h3>话题数</h3>
                                        <p>
                                        <%int sum6 = (int)session.getAttribute("sum6"); %>
                                            <cite><%=sum6 %></cite></p>
                                    </a> 
                                </li>	 
                            </ul>
                        </div>
                    </div>
                </div>
                <div class="layui-col-sm6 layui-col-md3">
                <%int c = (int)session.getAttribute("c"); %>
                <%int x = (int)session.getAttribute("x"); %>
                <%int z = (int)session.getAttribute("z"); %>
                <%int v = (int)session.getAttribute("v"); %>
                    <div class="layui-card">
                        <div class="layui-card-header">用户
                            <span class="layui-badge layui-bg-cyan layuiadmin-badge">周</span></div>
                        <div class="layui-card-body  ">
                            <p class="layuiadmin-big-font yan"><%=c %></p>
                            <p>新注册
                                <!-- <span class="layuiadmin-span-color">10% -->
                                    <i class="layui-inline layui-icon layui-icon-face-smile-b"></i></span>
                            </p>
                        </div>
                    </div>
                </div>
                <div class="layui-col-sm6 layui-col-md3">
                    <div class="layui-card">
                        <div class="layui-card-header">作品
                            <span class="layui-badge layui-bg-cyan layuiadmin-badge">周</span></div>
                        <div class="layui-card-body ">
                            <p class="layuiadmin-big-font yan"><%=x %></p>
                            <p>新发布
                                <!-- <span class="layuiadmin-span-color">10% -->
                                    <i class="layui-inline layui-icon layui-icon-face-smile-b"></i></span>
                            </p>
                        </div>
                    </div>
                </div>
                <div class="layui-col-sm6 layui-col-md3">
                    <div class="layui-card">
                        <div class="layui-card-header">日志
                            <span class="layui-badge layui-bg-cyan layuiadmin-badge">周</span></div>
                        <div class="layui-card-body ">
                            <p class="layuiadmin-big-font yan"><%=z %></p>
                            <p>新发布
                                <!-- <span class="layuiadmin-span-color">10% -->
                                    <i class="layui-inline layui-icon layui-icon-face-smile-b"></i></span>
                            </p>
                        </div>
                    </div>
                </div>
                <div class="layui-col-sm6 layui-col-md3">
                    <div class="layui-card">
                        <div class="layui-card-header">话题
                            <span class="layui-badge layui-bg-cyan layuiadmin-badge">周</span></div>
                        <div class="layui-card-body ">
                            <p class="layuiadmin-big-font yan"><%=v %></p>
                            <p>新发布
                                <!-- <span class="layuiadmin-span-color">10% -->
                                    <i class="layui-inline layui-icon layui-icon-face-smile-b"></i></span>
                            </p>
                        </div>
                    </div>
                </div>    
     
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-header">开发团队</div>
                        <div class="layui-card-body ">
                            <table class="layui-table">
                                <tbody>
                                    
                                    <tr>
                                        <th>开发者</th>
                                        <td><b style="color:maroon">刘宇</b>,&nbsp;&nbsp;张浩,&nbsp;&nbsp;谭梅丽,&nbsp;&nbsp;杜昕泽,&nbsp;&nbsp;朱丽良,&nbsp;&nbsp;聂克杰</td></tr>
                                </tbody>
                            </table>
                        </div>
                    </div>
                </div>
                <style id="welcome_style"></style>
                <div class="layui-col-md12 ke">
                    <blockquote class="layui-elem-quote layui-quote-nm  "  ">感谢大家的齐心协力!!!</blockquote>
                </div>
            </div>
        </div>
        </div>
    </body>
</html>